package cn.theten52.demo.patterns.design.behavior.mediation.update2;

/**
 * TODO
 *
 * @author wangjin
 * @date 2021/4/3
 */
public class Client {
    public static void main(String[] args) {
        MasterMediator master = new MasterMediator();
        Wudang wudang = new Wudang(master);
        Emei emei = new Emei(master);
        Shaolin shaolin = new Shaolin(master);
        master.setWudang(wudang);
        master.setEmei(emei);
        master.setShaolin(shaolin);
        wudang.sendMessage("武当弟子被少林所伤");
        emei.sendMessge("峨眉弟子被少林所伤");
        shaolin.sendMessage("误会，不可能，绝对不可能！");
    }
}
